﻿using LiteNetLib.Utils;
using Script.UiSystem;
using SimpleTools.Json;
using UnityEngine;

namespace Script.NetSystem.Services.RoomAndBattle.BattleService.Handler
{
    class Setpos : IBattleHandler
    {
        public void Handler(BattleClient battleClient, NetDataReader reader)
        {
            int id = reader.GetInt();
            float x = reader.GetFloat();
            float y = reader.GetFloat();
            float z = reader.GetFloat();

            battleClient.BattleManager.playerManager.UpdatePlayerPos(id, new Vector3(x,y,z));
        }
    }
}
